<%= form_for(@supplier) do |f| %>
  <% if @supplier.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(@supplier.errors.count, "error") %> prohibited this supplier from being saved:</h2>

      <ul>
      <% @supplier.errors.full_messages.each do |msg| %>
        <li><%= msg %></li>
      <% end %>
      </ul>
    </div>
  <% end %>

  <div class="field">
    <%= t 'activerecord.attributes.supplier.name' %><br />
    <%= f.text_field :name %>
  </div>
  <div class="field">
    <%= t 'activerecord.attributes.supplier.code' %><br />
    <%= f.text_field :code %>
  </div>
  <div class="field">
    <%= t 'activerecord.attributes.supplier.phone' %><br />
    <%= f.text_field :phone %>
  </div>
  <div class="field">
    <%= t 'activerecord.attributes.supplier.address' %><br />
    <%= f.text_field :address %>
  </div>
  <div class="actions">
    <%= f.submit %>
  </div>
<% end %>
